/**
 * Copyright (c) 2000-2013 Liferay, Inc. All rights reserved.
 *
 * This library is free software; you can redistribute it and/or modify it under
 * the terms of the GNU Lesser General Public License as published by the Free
 * Software Foundation; either version 2.1 of the License, or (at your option)
 * any later version.
 *
 * This library is distributed in the hope that it will be useful, but WITHOUT
 * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS
 * FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public License for more
 * details.
 */

package com.portlet.donggoi.service.persistence;

import com.liferay.portal.service.persistence.BasePersistence;

import com.portlet.donggoi.model.quytrinhDG;

/**
 * The persistence interface for the quytrinh d g service.
 *
 * <p>
 * Caching information and settings can be found in <code>portal.properties</code>
 * </p>
 *
 * @author Thi
 * @see quytrinhDGPersistenceImpl
 * @see quytrinhDGUtil
 * @generated
 */
public interface quytrinhDGPersistence extends BasePersistence<quytrinhDG> {
	/*
	 * NOTE FOR DEVELOPERS:
	 *
	 * Never modify or reference this interface directly. Always use {@link quytrinhDGUtil} to access the quytrinh d g persistence. Modify <code>service.xml</code> and rerun ServiceBuilder to regenerate this interface.
	 */

	/**
	* Caches the quytrinh d g in the entity cache if it is enabled.
	*
	* @param quytrinhDG the quytrinh d g
	*/
	public void cacheResult(com.portlet.donggoi.model.quytrinhDG quytrinhDG);

	/**
	* Caches the quytrinh d gs in the entity cache if it is enabled.
	*
	* @param quytrinhDGs the quytrinh d gs
	*/
	public void cacheResult(
		java.util.List<com.portlet.donggoi.model.quytrinhDG> quytrinhDGs);

	/**
	* Creates a new quytrinh d g with the primary key. Does not add the quytrinh d g to the database.
	*
	* @param maQuyTrinhDG the primary key for the new quytrinh d g
	* @return the new quytrinh d g
	*/
	public com.portlet.donggoi.model.quytrinhDG create(
		java.lang.String maQuyTrinhDG);

	/**
	* Removes the quytrinh d g with the primary key from the database. Also notifies the appropriate model listeners.
	*
	* @param maQuyTrinhDG the primary key of the quytrinh d g
	* @return the quytrinh d g that was removed
	* @throws com.portlet.donggoi.NoSuchquytrinhDGException if a quytrinh d g with the primary key could not be found
	* @throws SystemException if a system exception occurred
	*/
	public com.portlet.donggoi.model.quytrinhDG remove(
		java.lang.String maQuyTrinhDG)
		throws com.liferay.portal.kernel.exception.SystemException,
			com.portlet.donggoi.NoSuchquytrinhDGException;

	public com.portlet.donggoi.model.quytrinhDG updateImpl(
		com.portlet.donggoi.model.quytrinhDG quytrinhDG, boolean merge)
		throws com.liferay.portal.kernel.exception.SystemException;

	/**
	* Returns the quytrinh d g with the primary key or throws a {@link com.portlet.donggoi.NoSuchquytrinhDGException} if it could not be found.
	*
	* @param maQuyTrinhDG the primary key of the quytrinh d g
	* @return the quytrinh d g
	* @throws com.portlet.donggoi.NoSuchquytrinhDGException if a quytrinh d g with the primary key could not be found
	* @throws SystemException if a system exception occurred
	*/
	public com.portlet.donggoi.model.quytrinhDG findByPrimaryKey(
		java.lang.String maQuyTrinhDG)
		throws com.liferay.portal.kernel.exception.SystemException,
			com.portlet.donggoi.NoSuchquytrinhDGException;

	/**
	* Returns the quytrinh d g with the primary key or returns <code>null</code> if it could not be found.
	*
	* @param maQuyTrinhDG the primary key of the quytrinh d g
	* @return the quytrinh d g, or <code>null</code> if a quytrinh d g with the primary key could not be found
	* @throws SystemException if a system exception occurred
	*/
	public com.portlet.donggoi.model.quytrinhDG fetchByPrimaryKey(
		java.lang.String maQuyTrinhDG)
		throws com.liferay.portal.kernel.exception.SystemException;

	/**
	* Returns all the quytrinh d gs.
	*
	* @return the quytrinh d gs
	* @throws SystemException if a system exception occurred
	*/
	public java.util.List<com.portlet.donggoi.model.quytrinhDG> findAll()
		throws com.liferay.portal.kernel.exception.SystemException;

	/**
	* Returns a range of all the quytrinh d gs.
	*
	* <p>
	* Useful when paginating results. Returns a maximum of <code>end - start</code> instances. <code>start</code> and <code>end</code> are not primary keys, they are indexes in the result set. Thus, <code>0</code> refers to the first result in the set. Setting both <code>start</code> and <code>end</code> to {@link com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS} will return the full result set.
	* </p>
	*
	* @param start the lower bound of the range of quytrinh d gs
	* @param end the upper bound of the range of quytrinh d gs (not inclusive)
	* @return the range of quytrinh d gs
	* @throws SystemException if a system exception occurred
	*/
	public java.util.List<com.portlet.donggoi.model.quytrinhDG> findAll(
		int start, int end)
		throws com.liferay.portal.kernel.exception.SystemException;

	/**
	* Returns an ordered range of all the quytrinh d gs.
	*
	* <p>
	* Useful when paginating results. Returns a maximum of <code>end - start</code> instances. <code>start</code> and <code>end</code> are not primary keys, they are indexes in the result set. Thus, <code>0</code> refers to the first result in the set. Setting both <code>start</code> and <code>end</code> to {@link com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS} will return the full result set.
	* </p>
	*
	* @param start the lower bound of the range of quytrinh d gs
	* @param end the upper bound of the range of quytrinh d gs (not inclusive)
	* @param orderByComparator the comparator to order the results by (optionally <code>null</code>)
	* @return the ordered range of quytrinh d gs
	* @throws SystemException if a system exception occurred
	*/
	public java.util.List<com.portlet.donggoi.model.quytrinhDG> findAll(
		int start, int end,
		com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
		throws com.liferay.portal.kernel.exception.SystemException;

	/**
	* Removes all the quytrinh d gs from the database.
	*
	* @throws SystemException if a system exception occurred
	*/
	public void removeAll()
		throws com.liferay.portal.kernel.exception.SystemException;

	/**
	* Returns the number of quytrinh d gs.
	*
	* @return the number of quytrinh d gs
	* @throws SystemException if a system exception occurred
	*/
	public int countAll()
		throws com.liferay.portal.kernel.exception.SystemException;

	/**
	* Returns all the chi tiet q t dong gois associated with the quytrinh d g.
	*
	* @param pk the primary key of the quytrinh d g
	* @return the chi tiet q t dong gois associated with the quytrinh d g
	* @throws SystemException if a system exception occurred
	*/
	public java.util.List<com.portlet.donggoi.model.chiTietQTDongGoi> getchiTietQTDongGois(
		java.lang.String pk)
		throws com.liferay.portal.kernel.exception.SystemException;

	/**
	* Returns a range of all the chi tiet q t dong gois associated with the quytrinh d g.
	*
	* <p>
	* Useful when paginating results. Returns a maximum of <code>end - start</code> instances. <code>start</code> and <code>end</code> are not primary keys, they are indexes in the result set. Thus, <code>0</code> refers to the first result in the set. Setting both <code>start</code> and <code>end</code> to {@link com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS} will return the full result set.
	* </p>
	*
	* @param pk the primary key of the quytrinh d g
	* @param start the lower bound of the range of quytrinh d gs
	* @param end the upper bound of the range of quytrinh d gs (not inclusive)
	* @return the range of chi tiet q t dong gois associated with the quytrinh d g
	* @throws SystemException if a system exception occurred
	*/
	public java.util.List<com.portlet.donggoi.model.chiTietQTDongGoi> getchiTietQTDongGois(
		java.lang.String pk, int start, int end)
		throws com.liferay.portal.kernel.exception.SystemException;

	/**
	* Returns an ordered range of all the chi tiet q t dong gois associated with the quytrinh d g.
	*
	* <p>
	* Useful when paginating results. Returns a maximum of <code>end - start</code> instances. <code>start</code> and <code>end</code> are not primary keys, they are indexes in the result set. Thus, <code>0</code> refers to the first result in the set. Setting both <code>start</code> and <code>end</code> to {@link com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS} will return the full result set.
	* </p>
	*
	* @param pk the primary key of the quytrinh d g
	* @param start the lower bound of the range of quytrinh d gs
	* @param end the upper bound of the range of quytrinh d gs (not inclusive)
	* @param orderByComparator the comparator to order the results by (optionally <code>null</code>)
	* @return the ordered range of chi tiet q t dong gois associated with the quytrinh d g
	* @throws SystemException if a system exception occurred
	*/
	public java.util.List<com.portlet.donggoi.model.chiTietQTDongGoi> getchiTietQTDongGois(
		java.lang.String pk, int start, int end,
		com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
		throws com.liferay.portal.kernel.exception.SystemException;

	/**
	* Returns the number of chi tiet q t dong gois associated with the quytrinh d g.
	*
	* @param pk the primary key of the quytrinh d g
	* @return the number of chi tiet q t dong gois associated with the quytrinh d g
	* @throws SystemException if a system exception occurred
	*/
	public int getchiTietQTDongGoisSize(java.lang.String pk)
		throws com.liferay.portal.kernel.exception.SystemException;

	/**
	* Returns <code>true</code> if the chi tiet q t dong goi is associated with the quytrinh d g.
	*
	* @param pk the primary key of the quytrinh d g
	* @param chiTietQTDongGoiPK the primary key of the chi tiet q t dong goi
	* @return <code>true</code> if the chi tiet q t dong goi is associated with the quytrinh d g; <code>false</code> otherwise
	* @throws SystemException if a system exception occurred
	*/
	public boolean containschiTietQTDongGoi(java.lang.String pk,
		java.lang.String chiTietQTDongGoiPK)
		throws com.liferay.portal.kernel.exception.SystemException;

	/**
	* Returns <code>true</code> if the quytrinh d g has any chi tiet q t dong gois associated with it.
	*
	* @param pk the primary key of the quytrinh d g to check for associations with chi tiet q t dong gois
	* @return <code>true</code> if the quytrinh d g has any chi tiet q t dong gois associated with it; <code>false</code> otherwise
	* @throws SystemException if a system exception occurred
	*/
	public boolean containschiTietQTDongGois(java.lang.String pk)
		throws com.liferay.portal.kernel.exception.SystemException;
}